#ifndef _COMPONENT_H_
#define _COMPONENT_H_

#include "component.h"

XmlFile::XmlFile(const std::string filename)
{
	_actFile.open(filename.c_str());
	char tmp;
	_actFile >> tmp;	
	while(!_actFile.eof())
	{
		switch(tmp)
		{
			case '<':
				while(tmp != '>')
				{
					std::cout << tmp;
					_actFile >> tmp;		
				}
				std::cout << tmp;
				std::cout << std::endl;
				break;
			default:
				while(tmp != '<')
				{
					std::cout << tmp;
					_actFile >> tmp;		
				}
				std::cout << tmp;
				std::cout << std::endl;
				break;
		};
		
	}
};

XmlFile::~XmlFile()
{
    _actFile.close();
};


#endif
